<template>
  <div class="project-create-container container">
    <project-detail v-if="postForm" v-model="postForm" :is-edit="true" />
  </div>
</template>

<script>
import ProjectDetail from '@/views/project/components/ProjectDetail'
import { fetchProject } from '@/api/project'

export default {
  name: 'ProjectCreate',
  components: { ProjectDetail },
  data() {
    return {
      postForm: null
    }
  },
  created() {
    this.fetchData()
  },
  methods: {
    async fetchData() {
      const data = await fetchProject(this.$route.query.id)
      this.postForm = data.Data
    }
  }
}
</script>

<style scoped>

</style>
